<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=s, initial-scale=1.0">
    <title>行末的单行注释</title>
</head>

<body>
    <h2>JavaScript 注释</h2>
    <p id="demo"></p>
    <script>
        var x = 5;      // 声明 x，然后为其赋值 5
        var y = x + 2;  // 声明 y，然后为其赋值 x + 2 
        // 把 y 写入 demo
        document.getElementById("demo").innerHTML = y;
    </script>
</body>

</html>